﻿<%@ Page Language="C#" MasterPageFile="~/admin/admin.master" AutoEventWireup="true" CodeFile="edituser.aspx.cs" Inherits="admin_user_edituser" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <link href="../stylesheet/admin.css" rel="stylesheet" type="text/css" />
    <script src="../script/jquery-1.3.2.js" type="text/javascript"></script>
    
    <script src="../script/jquery-1.3.2-vsdoc2.js" type="text/javascript"></script>
    <script language="javascript" type="text/javascript">

        $(document).ready(function() {
            loadUser();

            $("#passwordchange").click(function() {
                alert("password change");
            });

            $("#userdetail").click(function() {
            alert("user detail change");
            });
        });
        function loadUser(userid) {
                PageMethod("getUser", [], OnUserLoadSuccess, OnUserLoadFailure);
            }

            function OnUserLoadSuccess(result, context, method) {
               $(result.d).each(function(i, o) {
                    $("#firstname").val(o.FirstName);
                    $("#lastname").val(o.LastName);
                    $("#email").val(o.Email); 
                });
            }
            function OnUserLoadFailure(result, context, method) {
            }
   
        </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server" EnableViewState="False">
<br/>
<div class="pad20left pad20right"><div id="pagebar"><span class="pad20left bigwhitebold">
    Edit a Existing User</span></div></div>
<br/>
<div class="inputform1">
<table cellspacing="0" class="inputtable1">
<tr><td class="bigboldbluetext" colspan="3">Change Password</td></tr>
<tr ><td>New Password</td><td>:</td><td id="new"><input type="text" id="newpassword" /></td></tr>
<tr><td>Retype Password</td><td>:</td><td><input type="text" id="retypepassword" /></td></tr>
<tr><td></td><td></td><td><div class="buttons"><a id="passwordchange"  href="#" >Save</a><a href="../dashboard.aspx" >Cancel</a></div></td></tr>
<tr><td></td><td></td><td><div id="resultbox1"><img id="resultimg1" src="" /> <label id="resulttxt1"  ></label></div></td></tr>
<tr><td colspan="3">&nbsp;</td></tr>
<tr><td class="bigboldbluetext" colspan="3">Change User Details</td></tr>
<tr ><td>First Name</td><td>:</td><td id="Td1"><input type="text" id="firstname" /></td></tr>
<tr><td>Last Name</td><td>:</td><td><input type="text" id="lastname" /></td></tr>
<tr><td>Email</td><td>:</td><td><input type="text" id="email" /></td></tr>
<tr><td></td><td></td><td><div class="buttons"><a id="userdetail"  href="#" >Save</a><a href="../dashboard.aspx" >Cancel</a></div></td></tr>
<tr><td></td><td></td><td><div id="resultbox2"><img id="resultimg2" src="" /> <label id="resulttxt2"  ></label></div></td></tr>

</table>
</div>

</asp:Content>

